home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Collection of Tools & Utilities
/
Collection of Tools and Utilities.iso
/
cattool
/
lbl420.zip
/
LABELER.PAS
< prev
next >
Wrap
Pascal/Delphi Source File
|
1989-12-17
|
50KB
|
1,458 lines
{ }
{ }
{ Program LABELER }
{ }
{ Author Ken Buetow CIS [71001,613] }
{ Guardian Software }
{ 26 Rose Street }
{ Baltic, Ct 06330-1028 }
{ }
{ Phone (203) 822-9212 [Voice] }
{ }
{ Date February 1, 1986 Last revised July 20, 1989 }
{ }
{ Language TURBO Pascal version 5 }
{ }
{ Remarks }
{ }
{ Utility to print disk labels on standard size }
{ one-up labels. }
{ }
{ Portions (c) Borland International }
{$V-}
{$S+} {Stack checking on}
{$I+} {I/O checking on}
{$N-} {No numeric coprocessor}
program labeler;
Uses
Crt,
Dos;
const
version = '4.20';
double = '═══════════════════════════════════════════════════════════════════════════════';
single = '───────────────────────────────────────────────────────────────────────────────';
long = '----------------------------------------------------------------';
max_files = 4096;
init_str :string = ^N^R^T^['F'^['H'^['T'^['9'^['2';
line_spacing :string = #27'3'#18;
sub_on :string = #27'S'#0;
sub_off :string = #27'T';
emp_on :string = #27'E';
emp_off :string = #27'F';
dbl_on :string = #14;
dbl_off :string = #20;
cond_on :string = #15;
cond_off :string = #18;
dbl_st_on :string = #27'G';
dbl_st_off :string = #27'H';
type_over : boolean = true;
registered: boolean = false;
labels = 10;
type
str_10 = string[10];
str_12 = string[13];
str_45 = string[65];
cmt_ptr= ^str_45;
fs_ptr = ^str_12;
var
test:integer;
lst,
cnf_file :text;
key :char;
reg :registers;
max_drive,
drive,
curr_dr :byte;
d_size,
used,
free :LongInt;
copies,
i,j,k,x,y,
count,
start,
printer,
num_files :integer;
temp_str,
disk_name,
library,
line,
mask_fs :string[255];
mask_file :text;
temp,
spaces,
blank_fs :str_12;
blank_cmt :str_45;
temp_fs :fs_ptr;
temp_cmt :cmt_ptr;
filespec :array[1..max_files] of record
name:fs_ptr;
cmt:cmt_ptr
end;
cont,
again,
abort,
blank :boolean;
s_rec :SearchRec;
size,
sizes :byte;
tcols :integer;
label_size:array[0..labels] of string;
wrap :array[0..labels] of boolean;
cols :array[0..labels] of integer;
rows :array[0..labels] of integer;
filler :array[0..labels] of integer;
feeds :array[0..labels] of integer;
dbl :array[0..labels] of boolean;
width :array[0..labels] of integer;
path :string;
function value(s:string):integer;
var i,c:integer;
begin
val(s,i,c);
value := i
end;
function parse(s:string):string;
var st:string;
begin
st := '';
while s[1] in ['0'..'9'] do
begin
st := st + chr(value(copy(s,1,pos(' ',s)-1)));
s := copy(s,pos(' ',s)+1,255)
end;
parse := st
end;
function Flop(c:char):string;
begin
case ord(c) of
0: flop := #27#76#9#0#0#0#0#0#0#0#0#0#0;
1: flop := #27#76#9#0#60#66#149#177#177#149#66#60#0;
2: flop := #27#76#9#0#60#126#235#207#207#235#126#60#0;
3: flop := #27#76#9#0#0#14#31#62#124#62#31#14#0;
4: flop := #27#76#9#0#0#8#28#62#127#62#28#8#0;
5: flop := #27#76#9#0#28#28#74#127#127#74#28#28#0;
6: flop := #27#76#9#0#8#28#94#127#127#94#28#8#0;
7: flop := #27#76#9#0#0#0#60#60#60#60#0#0#0;
8: flop := #27#76#9#0#255#255#195#195#195#195#255#255#0;
9: flop := #27#76#9#0#0#126#66#66#66#66#126#0#0;
10: flop := #27#76#9#0#255#129#189#189#189#189#129#255#0;
11: flop := #27#76#9#0#15#7#127#249#136#136#248#112#0;
12: flop := #27#76#9#0#0#0#78#95#241#241#95#78#0;
13: flop := #27#76#9#0#7#7#5#5#127#254#224#192#0;
14: flop := #27#76#9#0#63#127#101#5#5#127#254#192#0;
15: flop := #27#76#9#0#219#219#60#231#231#60#219#219#0;
16: flop := #27#76#9#0#0#8#8#28#62#62#127#127#0;
17: flop := #27#76#9#0#0#127#127#62#62#28#8#8#0;
18: flop := #27#76#9#0#0#0#36#102#255#255#102#36#0;
19: flop := #27#76#9#0#0#0#95#95#0#95#95#0#0;
20: flop := #27#76#9#0#127#127#1#127#127#17#31#14#0;
21: flop := #27#76#9#0#0#88#253#165#165#191#26#0#0;
22: flop := #27#76#9#0#0#112#112#112#112#112#112#112#0;
23: flop := #27#76#9#0#0#148#182#255#255#182#148#0#0;
24: flop := #27#76#9#0#0#0#4#6#127#127#6#4#0;
25: flop := #27#76#9#0#0#0#16#48#127#127#48#16#0;
26: flop := #27#76#9#0#0#8#28#62#8#8#8#8#0;
27: flop := #27#76#9#0#0#8#8#8#8#62#28#8#0;
28: flop := #27#76#9#0#0#16#16#16#16#16#28#28#0;
29: flop := #27#76#9#0#8#28#42#8#8#42#28#8#0;
30: flop := #27#76#9#0#0#48#56#60#62#60#56#48#0;
31: flop := #27#76#9#0#0#6#14#30#62#30#14#6#0;
32: flop := #27#76#9#0#0#0#0#0#0#0#0#0#0;
33: flop := #27#76#9#0#0#0#0#95#95#0#0#0#0;
34: flop := #27#76#9#0#0#0#7#7#0#0#7#7#0;
35: flop := #27#76#9#0#0#21#63#126#85#63#126#84#0;
36: flop := #27#76#9#0#0#18#58#43#107#106#46#36#0;
37: flop := #27#76#9#0#0#99#102#12#24#48#99#67#0;
38: flop := #27#76#9#0#0#80#114#55#93#79#122#48#0;
39: flop := #27#76#9#0#0#0#0#0#3#7#4#0#0;
40: flop := #27#76#9#0#0#0#65#99#62#28#0#0#0;
41: flop := #27#76#9#0#0#0#28#62#99#65#0#0#0;
42: flop := #27#76#9#0#0#8#42#62#28#62#42#8#0;
43: flop := #27#76#9#0#0#8#8#62#62#8#8#0#0;
44: flop := #27#76#9#0#0#0#0#96#224#128#0#0#0;
45: flop := #27#76#9#0#0#8#8#8#8#8#8#0#0;
46: flop := #27#76#9#0#0#0#0#96#96#0#0#0#0;
47: flop := #27#76#9#0#0#3#6#12#24#48#96#64#0;
48: flop := #27#76#9#0#0#62#127#71#77#89#127#62#0;
49: flop := #27#76#9#0#0#64#64#127#127#66#64#0#0;
50: flop := #27#76#9#0#0#102#111#73#89#81#115#98#0;
51: flop := #27#76#9#0#0#54#127#73#73#65#99#34#0;
52: flop := #27#76#9#0#0#16#127#127#19#22#28#24#0;
53: flop := #27#76#9#0#0#57#125#69#69#69#103#39#0;
54: flop := #27#76#9#0#0#48#121#73#73#75#126#60#0;
55: flop := #27#76#9#0#0#3#7#13#121#113#3#3#0;
56: flop := #27#76#9#0#0#54#127#73#73#73#127#54#0;
57: flop := #27#76#9#0#0#30#63#105#73#73#79#6#0;
58: flop := #27#76#9#0#0#0#0#102#102#0#0#0#0;
59: flop := #27#76#9#0#0#0#0#102#230#128#0#0#0;
60: flop := #27#76#9#0#0#0#65#99#54#28#8#0#0;
61: flop := #27#76#9#0#0#36#36#36#36#36#36#0#0;
62: flop := #27#76#9#0#0#8#28#54#99#65#0#0#0;
63: flop := #27#76#9#0#0#6#15#89#81#3#2#0#0;
64: flop := #27#76#9#0#0#30#95#93#93#65#127#62#0;
65: flop := #27#76#9#0#0#124#126#19#17#19#126#124#0;
66: flop := #27#76#9#0#0#54#127#107#73#127#127#65#0;
67: flop := #27#76#9#0#0#99#65#65#65#99#62#28#0;
68: flop := #27#76#9#0#0#62#62#99#65#127#127#65#0;
69: flop := #27#76#9#0#0#99#6